package com.zofer.study.decorator;

/**
 * @description 装饰模式
 * 假如需要建一栋别墅,先画好设计图,切好墙,接着装窗，再接着装门,....
 * 也可以先装门再装窗..
 * @date: 2020/9/29 16:29
 */
public class Main {

    public static void main(String[] args) {
        House house = new Door(new Windows(new Wall(new House("别墅设计图"))));
        System.out.println(house.getName());
    }
}
